export default {
  data() {
    return {}
  },
  methods: {
    // 查询列表数据
    getType(fileName) {
      let types = [{
        name: "photo",
        value: "pngjpgbmpjpeg"
      }, {
        name: "video",
        value: "mp4flvm3u8"
      }, {
        name: "zip",
        value: "zip7zrargz"
      }, {
        name: "word",
        value: "docx"
      }, {
        name: "excel",
        value: "xlsx"
      }, {
        name: "word",
        value: "docx"
      }, {
        name: "PPT",
        value: "pptx"
      }, {
        name: "PDF",
        value: "pdf"
      }, {
        name: "unknown",
        value: ""
      }]
      let namesplit = fileName.split(".")
      let type = namesplit[namesplit.length - 1]
      for (let i of types) {
        if (i.value.indexOf(type) != -1) {
          return i.name
        }
      }
      return "unknown"
    }
  },
}
